import React, { FC } from 'react';
import styles from './index.module.scss'
import { componentConfGroup,ComponentConfType } from '../../../components/QuestionComponents';
function getComponent(c: ComponentConfType) {
    const {title,type,Component}=c
    return <div><Component/></div>
}
const Lib: FC = () => {
    return <div>
        {componentConfGroup.map((group) => {
            const {groupName, components} = group
            return (
                <div key={groupName} >
                    <p>{groupName}</p>
                    <div className={styles.demo} >
                       <div>
                        {components.map(c=>getComponent(c))}
                        </div>
                    </div>
                </div>)
        })}

    </div>
}
export default Lib;